import request from '@/utils/request'

export const pageEmpList = 
(searchForm, page, pageSize) =>
  request.get(`/emps?name=${searchForm.name}&gender=${searchForm.gender}&begin=${searchForm.begin}&end=${searchForm.end}&page=${page}&pageSize=${pageSize}`);

export const addEmp =(data)=> request.post("/emps",data);

export const getEmpById=(id) => request.get(`/emps/${id}`);

export const updateEmpById=(data)=> request.put("/emps",data);

export const deleteEmpById=(id)=> request.delete("/emps?ids="+id);